######################################################
# 图形
######################################################
# 散点图
library("nutshell")
data("toxins.and.cancer")

attach(toxins.and.cancer) #不必敲数据框的名字
plot(total_toxic_chemicals/Surface_Area, deaths_lung/Population)
locator(1)
identify(air_on_site/Surface_Area, deaths_lung/Population, State_Abbrev)
text(air_on_site/Surface_Area, deaths_lung/Population,
     labels = State_Abbrev,
     cex = 0.5,
     adj = c(0, -1))
